<?php
class ArticlesController extends Controller
{
    function actionIndex()
    {
        $articles = new ArticlesModel();
        $this->view->render('articles', array('articles' => $articles->getArticlesAll()));
    }

    function actionView($alias)
    {
        $article = new ArticlesModel();
        $this->view->render('articleView', array('article' => $article->getArticle($alias)));
    }

}